-- GENERATED SPELL FOR [Lightsworn Vindicator] --


function spell0_22861(pUnit, Event) --@Exorcism,n/a--
pUnit:FullCastSpellOnTarget(33632,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_22861', 576, 1)
end

function spell1_22861(pUnit, Event) --@Hammer of Justice,n/a--
pUnit:FullCastSpellOnTarget(13005,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_22861', 6303, 1)
end

function spell2_22861(pUnit, Event) --@Holy Light,Heal--
pUnit:FullCastSpellOnTarget(13952,pUnit)
pUnit:RegisterEvent('Sorts_22861', 2500, 1)
end

function spell3_22861(pUnit, Event) --@Redemption,Heal--
pUnit:FullCastSpellOnTarget(39794,pUnit)
pUnit:RegisterEvent('Sorts_22861', 4000, 1)
end

function spell4_22861(pUnit, Event) --@Seal of Sacrifice,n/a--
pUnit:FullCastSpellOnTarget(13903,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_22861', 30263, 1)
end

function Sorts_22861(pUnit, Event)
local choix_sorts_22861 = math.random(0, 4)
if choix_sorts_22861 == 0 then
pUnit:RegisterEvent('spell0_22861', 1, 1)
end
if choix_sorts_22861 == 1 then
pUnit:RegisterEvent('spell1_22861', 1, 1)
end
if choix_sorts_22861 == 2 then
pUnit:RegisterEvent('spell2_22861', 1, 1)
end
if choix_sorts_22861 == 3 then
pUnit:RegisterEvent('spell3_22861', 1, 1)
end
if choix_sorts_22861 == 4 then
pUnit:RegisterEvent('spell4_22861', 1, 1)
end
end

function mob22861_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_22861', math.random(1500, 3000), 1)
end

function mob22861_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob22861_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob22861_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(22861, 1, 'mob22861_Action')
RegisterUnitEvent(22861, 2, 'mob22861_Leave')
RegisterUnitEvent(22861, 3, 'mob22861_Kill')
RegisterUnitEvent(22861, 4, 'mob22861_Die')
